package org.dgutstu.dgutshop.db.dao;

import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.dgutstu.dgutshop.db.domain.DgutshopAdmin;
import org.dgutstu.dgutshop.db.domain.DgutshopAdminExample;
import org.dgutstu.dgutshop.db.domain.DgutshopPermission;
import org.dgutstu.dgutshop.db.domain.DgutshopRole;

public interface DgutshopAdminMapper {
    //  非数据库字段

    /**
     * 通过用户ID查询角色集合
     * @Param  userId 用户ID
     * @Return List<SysRoleEntity> 角色名集合
     */
    List<DgutshopRole> selectRoleByUserId(Integer userId);
    /**
     * 通过用户ID查询权限集合
     * @Param  userId 用户ID
     * @Return List<SysMenuEntity> 角色名集合
     */
    List<DgutshopPermission> selectPermissionByUserId(Integer userId);
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    long countByExample(DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int deleteByExample(DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int deleteByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int insert(DgutshopAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int insertSelective(DgutshopAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    DgutshopAdmin selectOneByExample(DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    DgutshopAdmin selectOneByExampleSelective(@Param("example") DgutshopAdminExample example, @Param("selective") DgutshopAdmin.Column ... selective);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    List<DgutshopAdmin> selectByExampleSelective(@Param("example") DgutshopAdminExample example, @Param("selective") DgutshopAdmin.Column ... selective);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    List<DgutshopAdmin> selectByExample(DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    DgutshopAdmin selectByPrimaryKeySelective(@Param("id") Integer id, @Param("selective") DgutshopAdmin.Column ... selective);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    DgutshopAdmin selectByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    DgutshopAdmin selectByPrimaryKeyWithLogicalDelete(@Param("id") Integer id, @Param("andLogicalDeleted") boolean andLogicalDeleted);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int updateByExampleSelective(@Param("record") DgutshopAdmin record, @Param("example") DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int updateByExample(@Param("record") DgutshopAdmin record, @Param("example") DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int updateByPrimaryKeySelective(DgutshopAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int updateByPrimaryKey(DgutshopAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int logicalDeleteByExample(@Param("example") DgutshopAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table dgutshop_admin
     *
     * @mbg.generated
     */
    int logicalDeleteByPrimaryKey(Integer id);
}